import React, { Component } from 'react';
import { BrowserRouter as Router, Route, Switch } from 'react-router-dom';

import Links from '@/views/nav';
import Home from '@/views/home';
import Apple from '@/views/apple';
import User from '@/views/user';
import NotFound from '@/views/404';

export default class APP extends Component {
  render() {
    return (
      <Router>
        <div className="page">
          <Links />
          <Switch>
            <Route exact path="/" component={Home} />
            <Route exact path="/apple" component={Apple} />
            <Route exact path="/user" component={User} />
            <Route component={NotFound} />
          </Switch>
        </div>
      </Router>
    );
  }
}
